3.12 \(\int \frac {1}{\sqrt {a+b \csc ^2(c+d x)}} \, dx\)

Optimal. Leaf size=39 \[ -\frac {\tan ^{-1}\left (\frac {\sqrt {a} \cot (c+d x)}{\sqrt {a+b \csc ^2(c+d x)}}\right )}{\sqrt {a} d} \]

[Out]

-arctan(cot(d*x+c)*a^(1/2)/(a+b*csc(d*x+c)^2)^(1/2))/d/a^(1/2)

________________________________________________________________________________________

Rubi [A]  time = 0.04, antiderivative size = 40, normalized size of antiderivative = 1.03, number of steps used = 3, number of rules used = 3, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.188, Rules used = {4128, 377, 203} \[ -\frac {\tan ^{-1}\left (\frac {\sqrt {a} \cot (c+d x)}{\sqrt {a+b \cot ^2(c+d x)+b}}\right )}{\sqrt {a} d} \]

Antiderivative was successfully verified.

[In]

Int[1/Sqrt[a + b*Csc[c + d*x]^2],x]

[Out]

-(ArcTan[(Sqrt[a]*Cot[c + d*x])/Sqrt[a + b + b*Cot[c + d*x]^2]]/(Sqrt[a]*d))

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 377

Int[((a_) + (b_.)*(x_)^(n_))^(p_)/((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Subst[Int[1/(c - (b*c - a*d)*x^n), x]
, x, x/(a + b*x^n)^(1/n)] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && EqQ[n*p + 1, 0] && IntegerQ[n]

Rule 4128

Int[((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^2)^(p_), x_Symbol] :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Dist
[ff/f, Subst[Int[(a + b + b*ff^2*x^2)^p/(1 + ff^2*x^2), x], x, Tan[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p},
 x] && NeQ[a + b, 0] && NeQ[p, -1]

Rubi steps

\begin {align*} \int \frac {1}{\sqrt {a+b \csc ^2(c+d x)}} \, dx &=-\frac {\operatorname {Subst}\left (\int \frac {1}{\left (1+x^2\right ) \sqrt {a+b+b x^2}} \, dx,x,\cot (c+d x)\right )}{d}\\ &=-\frac {\operatorname {Subst}\left (\int \frac {1}{1+a x^2} \, dx,x,\frac {\cot (c+d x)}{\sqrt {a+b+b \cot ^2(c+d x)}}\right )}{d}\\ &=-\frac {\tan ^{-1}\left (\frac {\sqrt {a} \cot (c+d x)}{\sqrt {a+b+b \cot ^2(c+d x)}}\right )}{\sqrt {a} d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B]  time = 0.15, size = 98, normalized size = 2.51 \[ -\frac {\csc (c+d x) \sqrt {a \cos (2 (c+d x))-a-2 b} \log \left (\sqrt {a \cos (2 (c+d x))-a-2 b}+\sqrt {2} \sqrt {a} \cos (c+d x)\right )}{\sqrt {2} \sqrt {a} d \sqrt {a+b \csc ^2(c+d x)}} \]

Antiderivative was successfully verified.

[In]

Integrate[1/Sqrt[a + b*Csc[c + d*x]^2],x]

[Out]

-((Sqrt[-a - 2*b + a*Cos[2*(c + d*x)]]*Csc[c + d*x]*Log[Sqrt[2]*Sqrt[a]*Cos[c + d*x] + Sqrt[-a - 2*b + a*Cos[2
*(c + d*x)]]])/(Sqrt[2]*Sqrt[a]*d*Sqrt[a + b*Csc[c + d*x]^2]))

________________________________________________________________________________________

fricas [B]  time = 0.66, size = 414, normalized size = 10.62 \[ \left [-\frac {\sqrt {-a} \log \left (128 \, a^{4} \cos \left (d x + c\right )^{8} - 256 \, {\left (a^{4} + a^{3} b\right )} \cos \left (d x + c\right )^{6} + 160 \, {\left (a^{4} + 2 \, a^{3} b + a^{2} b^{2}\right )} \cos \left (d x + c\right )^{4} + a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4} - 32 \, {\left (a^{4} + 3 \, a^{3} b + 3 \, a^{2} b^{2} + a b^{3}\right )} \cos \left (d x + c\right )^{2} + 8 \, {\left (16 \, a^{3} \cos \left (d x + c\right )^{7} - 24 \, {\left (a^{3} + a^{2} b\right )} \cos \left (d x + c\right )^{5} + 10 \, {\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} \cos \left (d x + c\right )^{3} - {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )\right )} \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right )^{2} - a - b}{\cos \left (d x + c\right )^{2} - 1}} \sin \left (d x + c\right )\right )}{8 \, a d}, \frac {\arctan \left (\frac {{\left (8 \, a^{2} \cos \left (d x + c\right )^{4} - 8 \, {\left (a^{2} + a b\right )} \cos \left (d x + c\right )^{2} + a^{2} + 2 \, a b + b^{2}\right )} \sqrt {a} \sqrt {\frac {a \cos \left (d x + c\right )^{2} - a - b}{\cos \left (d x + c\right )^{2} - 1}} \sin \left (d x + c\right )}{4 \, {\left (2 \, a^{3} \cos \left (d x + c\right )^{5} - 3 \, {\left (a^{3} + a^{2} b\right )} \cos \left (d x + c\right )^{3} + {\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} \cos \left (d x + c\right )\right )}}\right )}{4 \, \sqrt {a} d}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(a+b*csc(d*x+c)^2)^(1/2),x, algorithm="fricas")

[Out]

[-1/8*sqrt(-a)*log(128*a^4*cos(d*x + c)^8 - 256*(a^4 + a^3*b)*cos(d*x + c)^6 + 160*(a^4 + 2*a^3*b + a^2*b^2)*c
os(d*x + c)^4 + a^4 + 4*a^3*b + 6*a^2*b^2 + 4*a*b^3 + b^4 - 32*(a^4 + 3*a^3*b + 3*a^2*b^2 + a*b^3)*cos(d*x + c
)^2 + 8*(16*a^3*cos(d*x + c)^7 - 24*(a^3 + a^2*b)*cos(d*x + c)^5 + 10*(a^3 + 2*a^2*b + a*b^2)*cos(d*x + c)^3 -
 (a^3 + 3*a^2*b + 3*a*b^2 + b^3)*cos(d*x + c))*sqrt(-a)*sqrt((a*cos(d*x + c)^2 - a - b)/(cos(d*x + c)^2 - 1))*
sin(d*x + c))/(a*d), 1/4*arctan(1/4*(8*a^2*cos(d*x + c)^4 - 8*(a^2 + a*b)*cos(d*x + c)^2 + a^2 + 2*a*b + b^2)*
sqrt(a)*sqrt((a*cos(d*x + c)^2 - a - b)/(cos(d*x + c)^2 - 1))*sin(d*x + c)/(2*a^3*cos(d*x + c)^5 - 3*(a^3 + a^
2*b)*cos(d*x + c)^3 + (a^3 + 2*a^2*b + a*b^2)*cos(d*x + c)))/(sqrt(a)*d)]

________________________________________________________________________________________

giac [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: TypeError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(a+b*csc(d*x+c)^2)^(1/2),x, algorithm="giac")

[Out]

Exception raised: TypeError >> An error occurred running a Giac command:INPUT:sage2:=int(sage0,x):;OUTPUT:Warn
ing, integration of abs or sign assumes constant sign by intervals (correct if the argument is real):Check [ab
s(sin(d*x+c))]Unable to check sign: (2*pi/t_nostep/2)>(-2*pi/t_nostep/2)Unable to check sign: (2*pi/t_nostep/2
)>(-2*pi/t_nostep/2)Unable to check sign: (2*pi/t_nostep/2)>(-2*pi/t_nostep/2)Unable to check sign: (2*pi/t_no
step/2)>(-2*pi/t_nostep/2)Unable to check sign: (2*pi/t_nostep/2)>(-2*pi/t_nostep/2)Unable to check sign: (2*p
i/t_nostep/2)>(-2*pi/t_nostep/2)Unable to check sign: (2*pi/t_nostep/2)>(-2*pi/t_nostep/2)Unable to check sign
: (2*pi/t_nostep/2)>(-2*pi/t_nostep/2)Warning, replacing 0 by ` u`, a substitution variable should perhaps be
purged.Warning, replacing 0 by ` u`, a substitution variable should perhaps be purged.Warning, replacing 0 by
` u`, a substitution variable should perhaps be purged.Warning, replacing 0 by ` u`, a substitution variable s
hould perhaps be purged.Warning, replacing 0 by ` u`, a substitution variable should perhaps be purged.Warning
, replacing 0 by ` u`, a substitution variable should perhaps be purged.Warning, replacing 0 by ` u`, a substi
tution variable should perhaps be purged.Warning, replacing 0 by ` u`, a substitution variable should perhaps
be purged.Warning, replacing 0 by ` u`, a substitution variable should perhaps be purged.Warning, integration
of abs or sign assumes constant sign by intervals (correct if the argument is real):Check [abs(t_nostep)]Warni
ng, need to choose a branch for the root of a polynomial with parameters. This might be wrong.Non regular valu
e [0] was discarded and replaced randomly by 0=[-77]Warning, need to choose a branch for the root of a polynom
ial with parameters. This might be wrong.Non regular value [0] was discarded and replaced randomly by 0=[82]Wa
rning, need to choose a branch for the root of a polynomial with parameters. This might be wrong.Non regular v
alue [0] was discarded and replaced randomly by 0=[15]Warning, need to choose a branch for the root of a polyn
omial with parameters. This might be wrong.Non regular value [0] was discarded and replaced randomly by 0=[-24
]Warning, need to choose a branch for the root of a polynomial with parameters. This might be wrong.Non regula
r value [0] was discarded and replaced randomly by 0=[16]Warning, need to choose a branch for the root of a po
lynomial with parameters. This might be wrong.Non regular value [0] was discarded and replaced randomly by 0=[
-59]Evaluation time: 0.66index.cc index_m operator + Error: Bad Argument Value

________________________________________________________________________________________

maple [B]  time = 1.46, size = 182, normalized size = 4.67 \[ \frac {\sin \left (d x +c \right ) \sqrt {-\frac {a \left (\cos ^{2}\left (d x +c \right )\right )-a -b}{\left (1+\cos \left (d x +c \right )\right )^{2}}}\, \ln \left (4 \sqrt {-a}\, \cos \left (d x +c \right ) \sqrt {-\frac {a \left (\cos ^{2}\left (d x +c \right )\right )-a -b}{\left (1+\cos \left (d x +c \right )\right )^{2}}}+4 \sqrt {-a}\, \sqrt {-\frac {a \left (\cos ^{2}\left (d x +c \right )\right )-a -b}{\left (1+\cos \left (d x +c \right )\right )^{2}}}-4 a \cos \left (d x +c \right )\right )}{d \sqrt {\frac {a \left (\cos ^{2}\left (d x +c \right )\right )-a -b}{\cos ^{2}\left (d x +c \right )-1}}\, \left (-1+\cos \left (d x +c \right )\right ) \sqrt {-a}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(a+b*csc(d*x+c)^2)^(1/2),x)

[Out]

1/d*sin(d*x+c)*(-(a*cos(d*x+c)^2-a-b)/(1+cos(d*x+c))^2)^(1/2)*ln(4*(-a)^(1/2)*cos(d*x+c)*(-(a*cos(d*x+c)^2-a-b
)/(1+cos(d*x+c))^2)^(1/2)+4*(-a)^(1/2)*(-(a*cos(d*x+c)^2-a-b)/(1+cos(d*x+c))^2)^(1/2)-4*a*cos(d*x+c))/((a*cos(
d*x+c)^2-a-b)/(cos(d*x+c)^2-1))^(1/2)/(-1+cos(d*x+c))/(-a)^(1/2)

________________________________________________________________________________________

maxima [B]  time = 0.66, size = 987, normalized size = 25.31 \[ \text {result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(a+b*csc(d*x+c)^2)^(1/2),x, algorithm="maxima")

[Out]

1/2*(arctan2(2*a*sin(2*d*x + 2*c) + 2*(a^2*cos(4*d*x + 4*c)^2 + a^2*sin(4*d*x + 4*c)^2 + 4*(a^2 + 4*a*b + 4*b^
2)*cos(2*d*x + 2*c)^2 - 4*(a^2 + 2*a*b)*sin(4*d*x + 4*c)*sin(2*d*x + 2*c) + 4*(a^2 + 4*a*b + 4*b^2)*sin(2*d*x
+ 2*c)^2 + a^2 + 2*(a^2 - 2*(a^2 + 2*a*b)*cos(2*d*x + 2*c))*cos(4*d*x + 4*c) - 4*(a^2 + 2*a*b)*cos(2*d*x + 2*c
))^(1/4)*sqrt(a)*sin(1/2*arctan2(a*sin(4*d*x + 4*c) - 2*(a + 2*b)*sin(2*d*x + 2*c), a*cos(4*d*x + 4*c) - 2*(a
+ 2*b)*cos(2*d*x + 2*c) + a)), 2*a*cos(2*d*x + 2*c) + 2*(a^2*cos(4*d*x + 4*c)^2 + a^2*sin(4*d*x + 4*c)^2 + 4*(
a^2 + 4*a*b + 4*b^2)*cos(2*d*x + 2*c)^2 - 4*(a^2 + 2*a*b)*sin(4*d*x + 4*c)*sin(2*d*x + 2*c) + 4*(a^2 + 4*a*b +
 4*b^2)*sin(2*d*x + 2*c)^2 + a^2 + 2*(a^2 - 2*(a^2 + 2*a*b)*cos(2*d*x + 2*c))*cos(4*d*x + 4*c) - 4*(a^2 + 2*a*
b)*cos(2*d*x + 2*c))^(1/4)*sqrt(a)*cos(1/2*arctan2(a*sin(4*d*x + 4*c) - 2*(a + 2*b)*sin(2*d*x + 2*c), a*cos(4*
d*x + 4*c) - 2*(a + 2*b)*cos(2*d*x + 2*c) + a)) - 2*a - 4*b) + arctan2(2*(a^2*cos(4*d*x + 4*c)^2 + a^2*sin(4*d
*x + 4*c)^2 + 4*(a^2 + 4*a*b + 4*b^2)*cos(2*d*x + 2*c)^2 - 4*(a^2 + 2*a*b)*sin(4*d*x + 4*c)*sin(2*d*x + 2*c) +
 4*(a^2 + 4*a*b + 4*b^2)*sin(2*d*x + 2*c)^2 + a^2 + 2*(a^2 - 2*(a^2 + 2*a*b)*cos(2*d*x + 2*c))*cos(4*d*x + 4*c
) - 4*(a^2 + 2*a*b)*cos(2*d*x + 2*c))^(1/4)*sqrt(a)*sin(1/2*arctan2(a*sin(4*d*x + 4*c) - 2*(a + 2*b)*sin(2*d*x
 + 2*c), a*cos(4*d*x + 4*c) - 2*(a + 2*b)*cos(2*d*x + 2*c) + a)), 2*(a^2*cos(4*d*x + 4*c)^2 + a^2*sin(4*d*x +
4*c)^2 + 4*(a^2 + 4*a*b + 4*b^2)*cos(2*d*x + 2*c)^2 - 4*(a^2 + 2*a*b)*sin(4*d*x + 4*c)*sin(2*d*x + 2*c) + 4*(a
^2 + 4*a*b + 4*b^2)*sin(2*d*x + 2*c)^2 + a^2 + 2*(a^2 - 2*(a^2 + 2*a*b)*cos(2*d*x + 2*c))*cos(4*d*x + 4*c) - 4
*(a^2 + 2*a*b)*cos(2*d*x + 2*c))^(1/4)*sqrt(a)*cos(1/2*arctan2(a*sin(4*d*x + 4*c) - 2*(a + 2*b)*sin(2*d*x + 2*
c), a*cos(4*d*x + 4*c) - 2*(a + 2*b)*cos(2*d*x + 2*c) + a)) - 4*b))/(sqrt(a)*d)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.03 \[ \int \frac {1}{\sqrt {a+\frac {b}{{\sin \left (c+d\,x\right )}^2}}} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(a + b/sin(c + d*x)^2)^(1/2),x)

[Out]

int(1/(a + b/sin(c + d*x)^2)^(1/2), x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{\sqrt {a + b \csc ^{2}{\left (c + d x \right )}}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(a+b*csc(d*x+c)**2)**(1/2),x)

[Out]

Integral(1/sqrt(a + b*csc(c + d*x)**2), x)

________________________________________________________________________________________